home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / NextAnswers / 2052_fdisk_manpage.txt < prev    next >
Text File  |  1995-10-12  |  7KB  |  198 lines

  1.  
  2.  
  3. FDISK(8)        UNIX Programmer's Manual         FDISK(8)
  4.  
  5. NAME
  6.      fdisk - examine or change DOS partitioning information
  7.  
  8. SYNOPSIS
  9.      /usr/etc/fdisk <raw-device> [ inquiry ] [ action ] [ flags ]
  10.  
  11. DESCRIPTION
  12.      fdisk displays or changes the DOS partition table found in
  13.      the bootsector of i386 bootable disks.  If no inquiry or
  14.      action is specified, it is run in interactive mode, allowing
  15.      multiple changes to the partition table to be made.  If an
  16.      inquiry is specified, the result is displayed to standard
  17.      output but no changes to the partition table are made.  If
  18.      an action is requested, the partition table will usually be
  19.      modified and fdisk immediately returns.  When fdisk is run
  20.      in interactive mode, no changes to the partition table are
  21.      effected until the user explicitly writes the changes.
  22.  
  23.      fdisk modifies only the bootsector and (unless the -bootsec-
  24.      torOnly flag is specified) the first sector of newly allo-
  25.      cated partitions; it does not modify other contents of the
  26.      disk in any way.  However, it is used to redefine the allo-
  27.      cation of the disk; deleting a partition makes the partition
  28.      inaccessible and should be considered tantamount to erasing
  29.      the partition.
  30.  
  31.      Flags
  32.  
  33.      -useAllSectors
  34.        For compatibility with the DOS version, fdisk by
  35.        default recognizes only those sectors that are bios-
  36.        accessible.    However, if fdisk is passed the
  37.        -useAllSectors flag, it will recognize all sectors
  38.        physically present.    Data allocated in the extra sec-
  39.        tors may not be bios accessible, and certain fields in
  40.        the partition table might overflow, which might cause
  41.        problems with some operating systems.  Bios inaccessi-
  42.        ble sectors could prevent NEXTSTEP from booting,
  43.        though once booted NEXTSTEP is unaffected by bios lim-
  44.        itations or partition table overflows.
  45.  
  46.      -useBoot0
  47.        Reads in /usr/standalone/i386/boot0 to be used as the
  48.        partition boot program.  If this option is not speci-
  49.        fied, the existing boot program is retained.
  50.  
  51.      -bootsectorOnly
  52.        Tells fdisk to modify only the bootsector when saving
  53.        changes.  Otherwise, the default behavior is to zero
  54.        the first sector of newly-created partitions to ensure
  55.        that extant data is not treated as a boot program or
  56.        meaningful partition information.
  57.  
  58.      Interactive mode
  59.  
  60.      When fdisk is run in interactive mode, it displays the
  61.      defined partitions and unallocated disk space, then displays
  62.      a menu.  Information on defined partitions includes:
  63.  
  64.      Type  The type of data the partition is said to contain.
  65.  
  66.      Start The starting address of the partition, in megabytes.
  67.  
  68.      Size  The size of the partition, in megabytes.
  69.  
  70.      Status
  71.        If the partition is marked as active, the partition
  72.        will be booted from when the selected device is the
  73.        boot device.
  74.  
  75.      All unused blocks on the disk are also displayed, with their
  76.      sizes rounded to the nearest megabyte.
  77.  
  78.      Interactive mode main menu options
  79.  
  80.      Create a new partition
  81.        Allocates space on the disk for use by NEXTSTEP or
  82.        another operating system.  The space is allocated from
  83.        the first adequate free block.  The partition table
  84.        structure only allows for 4 partitions per disk.
  85.  
  86.      Delete partition
  87.        Deallocates the space occupied by the specified parti-
  88.        tion.
  89.  
  90.      Set the active partition
  91.        Specifies which partition is to be booted from if the
  92.        selected device is the boot device.
  93.  
  94.      Show disk information
  95.        Displays the layout of the disk, both according to the
  96.        driver and accoring to the rom bios.  For compatibil-
  97.        ity with the DOS verstion, fdisk by default only
  98.        recognizes those sectors that are bios-accessible.
  99.        However, if fdisk is passed the -useAllSectors flag,
  100.        it will recognize all sectors physically present.
  101.  
  102.      Non-interactive mode
  103.  
  104.      For the benefit of installation scripts, fdisk can be given
  105.      one inquiry or one action to effect partitioning.    Inquiries
  106.      do not modify the partition table, but actions usually do.
  107.  
  108.      The following inquiries are allowed:
  109.  
  110.      -isDiskPartitioned
  111.        Outputs "Yes" if the disk contains 1 or more valid
  112.        partitions, "No" otherwise.
  113.  
  114.      -isThereExtendedPartition
  115.        Outputs "Yes" if the disk has a DOS extended
  116.        partition, "No" otherwise.
  117.  
  118.      -isThereNeXTPartition
  119.        Outputs "Yes" if the disk has a NEXTSTEP partition,
  120.        "No" otherwise.
  121.  
  122.      -freeSpace
  123.        Outputs the size (in megabytes) of the largest free
  124.        block on the disk.
  125.  
  126.      -freeWONeXT
  127.        Outputs the size (in megabytes) of the largest free
  128.        block on the disk if the NEXTSTEP partition were
  129.        deleted.
  130.  
  131.      -freeWONeXTorExt
  132.        Outputs the size (in megabytes) of the largest free
  133.        block on the disk if the NEXTSTEP and extended parti-
  134.        tions were deleted.
  135.  
  136.      -sizeofExtended
  137.        Outputs the size (in megabytes) of the extended parti-
  138.        tion.
  139.  
  140.      -diskSize
  141.        Outputs the size of the disk in megabytes.
  142.  
  143.      -installSize
  144.        Outputs the size that NEXTSTEP would install to on the
  145.        current disk; effectively the size of the NEXTSTEP
  146.        partition if the disk is partitioned, otherwise the
  147.        size of the disk.
  148.  
  149.      The following actions are allowed:
  150.  
  151.      -removePartitioning
  152.        Zeros out the bootsector, eliminating the partition
  153.        table and boot program.  Prepares the disk so that
  154.        NEXTSTEP will install on the entire disk.
  155.  
  156.      -dosPlusNeXT <megsForDos>
  157.        Partitions the disk with <megsForDos> reserved for DOS
  158.        and the remainder used for NEXTSTEP.
  159.  
  160.      -setAvailableToNeXT
  161.        Deletes the current NEXTSTEP partition, then reserves
  162.        the largest free space for NEXTSTEP; doesn't destroy
  163.        other partitions.
  164.  
  165.      -setExtAndAvailableToNeXT
  166.        Deletes the current NEXTSTEP and extended partitions,
  167.        then reserves the largest free space for NEXTSTEP;
  168.        doesn't destroy other partitions.
  169.  
  170.      -setExtendedToNeXT
  171.        Changes the current extended partition to NEXTSTEP.
  172.  
  173.      -setNeXTActive
  174.        Makes the NEXTSTEP partition active, but doesn't
  175.        affect the size of any partition.
  176.  
  177. SEE ALSO
  178.      disk(8)
  179.  
  180. BUGS
  181.      When creating a partition, fdisk's idea of a megabyte is
  182.      sometimes different than other versions; fdisk is not
  183.      guaranteed to locate the partition where another version
  184.      would.
  185.  
  186.      fdisk knows nothing about logical partitions, which are
  187.      sub-partitions of an extended partition.  Nor perhaps should
  188.      it, as these are gross kludges from the Evil OS Company of
  189.      the North.
  190.  
  191.      fdisk does not tolerate inconsistent partitions; a partition
  192.      that overlaps another will not be included in the partition
  193.      table when it is written out, and the cylinder/head/sector
  194.      bios values are derived from the absolute sector numbers.
  195.      Upon writing, the partition table entries are ordered the
  196.      same as the actual partitions.
  197.  
  198.